package com.fitns.user.constant;

public class Constants  {
	public static final String DATESTR = "yyyy-MM-dd HH:mm:ss";// 时间格式

    public static final String DATESTR2 = "yyyy-MM-dd";// 时间格式
	public static final String IMAGE_PATH="/data/wwwroot/mounted/img/";
	//public static final String IMAGE_PATH="E:\\mycode\\code\\zhhw\\src\\main\\resources\\image";
	public static final String PATH="http://woliuadmin.woliutech.cn:8888/imag/";

	public class PrivilegeGrade{
		public static final int TOP_GRADE = 1;
	}

	public class ORGAN_LEVEL{
		public static final int ALLOWED_LEVEL = 2;
		public static final int TOP_LEVEL = 0;
	}

	public class IS_BLNVALID{
		public static final int YES=0;
		public static final int NO=1;
	}

	public class ORGAN_TYPE_STRING{
		public static final String PRIVINCE="province";
		public static final String CITY="city";
		public static final String DISTRICT="district";
		public static final String COMPANY="company";
		public static final String AREA="area";
		public static final String SECTION="section";
		public static final String GROUP="group";

	}

	public  static enum STATUS  {
		OK(0, "正常"), //
		DELETE(1,"逻辑删除"), //
		;
		public  int type;
		public  String name;
		STATUS(int type,String name) {
			this.type = type;
			this.name = name;
		}
		public static String get(int v) {
			for (STATUS rft : STATUS.values()) {
				if (rft.type == v)
					return rft.name;
			}
			return null;
		}
		public static STATUS getByType(int v) {
			for (STATUS rft : STATUS.values()) {
				if (rft.type == v)
					return rft;
			}
			return null;
		}
	}
	//禁止，可用
	public  static enum ENABLED  {
		OK(0, "正常"), //
		DISABLED(1,"禁止"), //
		;
		public  int type;
		public  String name;
		ENABLED(int type,String name) {
			this.type = type;
			this.name = name;
		}
		public static String get(int v) {
			for (ENABLED rft : ENABLED.values()) {
				if (rft.type == v)
					return rft.name;
			}
			return null;
		}
		public static ENABLED getByType(int v) {
			for (ENABLED rft : ENABLED.values()) {
				if (rft.type == v)
					return rft;
			}
			return null;
		}
	}
	
}